package cn.edu.zafu.bigdata.lmr;

    class Book {
        private String title;
        private String author;
        private double price;

        public Book(String title, String author, double price) {
            this.title = title;
            this.author = author;
            this.price = price;
        }


        public String toString() {
            return "Book[title=" + title + ", author=" + author + ", price=" + price + "]";
        }

        public String getTitle() {
            return title;
        }

        public void setTitle(String title) {
            this.title = title;
        }

        public String getAuthor() {
            return author;
        }

        public void setAuthor(String author) {
            this.author = author;
        }

        public double getPrice() {
            return price;
        }

        public void setPrice(double price) {
            this.price = price;
        }
    }


    public class Test3 {
        public static void main(String[] args) {
            Book book1 = new Book("Java Programming", "John Doe", 29.99);
            Book book2 = new Book("Python", "b", 15.5);
            Book book3 = new Book("C", "c", 30.5);

            System.out.println(book1);
            System.out.println(book2);
            System.out.println(book3);
        }
    }
